package com.example.check.cooperative.mapper;

import com.example.check.cooperative.pojo.CooperativeItem;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface CooperativeItemMapper {

    List<CooperativeItem> selectByTripId(@Param("tripId") Integer tripId);

    int insert(CooperativeItem item);

    int updateCheckedStatus(@Param("id") Integer id, @Param("checked") Boolean checked);

    int deleteById(@Param("id") Integer id);

    int resetCheckedByTripId(@Param("tripId") Integer tripId);

    int deleteByTripId(@Param("tripId") Integer tripId);
}


